<?php

namespace app\modules\entrys\models;

use Yii;

/**
 * This is the model class for table "rah_regularapply".
 *
 * @property integer $regularWorkerAppID
 * @property integer $user_id
 * @property double $beforeRegularSalary
 * @property string $regularDate
 * @property double $afterRegularSalary
 * @property string $createUser
 * @property string $createTime
 * @property string $updateUser
 * @property string $updateTime
 * @property string $auditStatus
 * @property integer $status
 * @property string $comment
 * @property integer $workFlowSeqNo
 * @property double $regulayJiXiao
 * @property double $regulayBaseSalaryAmt
 * @property resource $leadsAndLags
 * @property resource $selfAssessment
 * @property resource $businessEarnings
 * @property resource $businessWorkmanship
 * @property resource $attitudeDiscipline
 * @property resource $attitudeAccountability
 * @property resource $attitudeInitiative
 * @property resource $attitudeInteroperability
 * @property resource $capacityJobSkill
 * @property resource $capacityExecution
 * @property resource $trialOpinion
 * @property integer $beforeRank
 * @property integer $afterRank
 * @property integer $beforeTravelAllowance
 * @property integer $beforeCommnicationAllowance
 * @property integer $beforePerformanceAllowance
 * @property integer $afterTravelAllowance
 * @property integer $afterCommnicationAllowance
 * @property integer $afterPerformanceAllowance
 * @property string $delayregularDate
 * @property resource $groupStr
 * @property string $duty
 * @property integer $AuditRoleComment
 *
 * @property RahRegularworkflow[] $rahRegularworkflows
 */
class Regularapply extends \yii\db\ActiveRecord
{
    /**
     * @inheritdoc
     */
    public static function tableName()
    {
        return 'rah_regularapply';
    }

    /**
     * @inheritdoc
     */
    public function rules()
    {
        return [
            [['user_id', 'status', 'workFlowSeqNo', 'beforeRank', 'afterRank', 'beforeTravelAllowance', 'beforeCommnicationAllowance', 'beforePerformanceAllowance', 'afterTravelAllowance', 'afterCommnicationAllowance', 'afterPerformanceAllowance', 'AuditRoleComment'], 'integer'],
            [['beforeRegularSalary', 'afterRegularSalary', 'regulayJiXiao', 'regulayBaseSalaryAmt'], 'number'],
            [['regularDate', 'createTime', 'updateTime', 'delayregularDate'], 'safe'],
            [['leadsAndLags', 'selfAssessment', 'businessEarnings', 'businessWorkmanship', 'attitudeDiscipline', 'attitudeAccountability', 'attitudeInitiative', 'attitudeInteroperability', 'capacityJobSkill', 'capacityExecution', 'trialOpinion', 'groupStr'], 'string'],
            [['createUser', 'updateUser'], 'string', 'max' => 20],
            [['auditStatus'], 'string', 'max' => 250],
            [['comment'], 'string', 'max' => 200],
            [['duty'], 'string', 'max' => 64],
        ];
    }

    /**
     * @inheritdoc
     */
    public function attributeLabels()
    {
        return [
            'regularWorkerAppID' => 'regularWorkerAppID',
            'user_id' => 'user_id',
            'beforeRegularSalary' => '转正前薪水(Wage)',
            'regularDate' => '转正日期(延迟转正日期)',
            'afterRegularSalary' => '转正后薪水(Wage)',
            'createUser' => '创建用户',
            'createTime' => '创建日期',
            'updateUser' => '更新用户',
            'updateTime' => '更新日期',
            'auditStatus' => '审核状态',
            'status' => '状态',
            'comment' => '自我陈述',
            'workFlowSeqNo' => '工作流流转号',
            'regulayJiXiao' => '转正绩效',
            'regulayBaseSalaryAmt' => '转正底薪',
            'leadsAndLags' => '是否提前或沿后',
            'selfAssessment' => '个人工作总结',
            'businessEarnings' => '业务考评业绩情况',
            'businessWorkmanship' => '业务考评工作质量',
            'attitudeDiscipline' => '态度考评纪律性',
            'attitudeAccountability' => '态度考评责任性',
            'attitudeInitiative' => '态度考评主动性',
            'attitudeInteroperability' => '态度考评协作性',
            'capacityJobSkill' => '能力考评岗位技能',
            'capacityExecution' => '能力考评执行能力',
            'trialOpinion' => '部门适用意见',
            'beforeRank' => '职级',
            'afterRank' => '职级',
            'beforeTravelAllowance' => '转正前交通补贴',
            'beforeCommnicationAllowance' => '转正前通讯补贴',
            'beforePerformanceAllowance' => '转正前业绩补贴',
            'afterTravelAllowance' => '转正后交通补贴',
            'afterCommnicationAllowance' => '转正后通讯补贴',
            'afterPerformanceAllowance' => '转正后业绩补贴',
            'delayregularDate' => '延期转正日期',
            'groupStr' => '组织',
            'duty' => '职位',
            'AuditRoleComment' => '总部人事审核流程，0为审核人1为空，1为正常',
        ];
    }

    /**
     * @return \yii\db\ActiveQuery
     */
    public function getRahRegularworkflows()
    {
        return $this->hasMany(RahRegularworkflow::className(), ['regularWorkerAppID' => 'regularWorkerAppID']);
    }
}
